// 不在需要高阶函数 直接获取state中的参数
import { useSelector } from 'react-redux'
import { StoreType } from '../interface'
import { Outlet } from 'react-router-dom'
import Header from '../components/Header'

const Home  = () => {

    const userInfo = useSelector((state:StoreType):any => {
        return state.userInfo
    })


    return <div className="public">
        {/* 公共头部 */}
        <Header/>
        {/* 内容 */}
        <div className="body">
            <Outlet/>
        </div>
    </div>
}

export default Home